/**************************************************************************/ /**
 * @file     file_table.h
 * @brief    素材储存管理
 * @version  V2.0
 * @date     2022.07.21
******************************************************************************/
#ifndef __FILE_TABLE_H__
#define __FILE_TABLE_H__

//----------------------------------头文件依赖---------------------------------//
#include "SWM341.h"
#include "version.h"

//----------------------------------素材参数配置---------------------------------//
#if (LCD_HDOT == 480 && LCD_VDOT == 272) // 480*272

#if (LCD_FMT == LCD_RGB565)
#include "define_480_272_ui_rgb.h"

#elif (LCD_FMT == LCD_RGB888)
#include "define_480_272_ui_rgb.h"

#endif // LCD_FORMAT

#elif (LCD_HDOT == 480 && LCD_VDOT == 480) // 480*480

#if (LCD_FMT == LCD_RGB565)
#include "define_480_480_ui_rgb.h"

#elif (LCD_FMT == LCD_RGB888)
#include "define_480_480_ui_rgb.h"

#endif // LCD_FORMAT

#elif (LCD_HDOT == 800 && LCD_VDOT == 480) // 800*480

#if (LCD_FMT == LCD_RGB565)
#include "define_800_480_ui_rgb.h"

#elif (LCD_FMT == LCD_RGB888)
#include "define_800_480_ui_rgb.h"

#endif // LCD_FORMAT

#elif (LCD_HDOT == 1024 && LCD_VDOT == 600) // 1024*600

#if (LCD_FMT == LCD_RGB565)
#include "define_1024_600_ui_rgb.h"

#elif (LCD_FMT == LCD_RGB888)
#include "define_1024_600_ui_rgb.h"

#endif // LCD_FORMAT

#endif //(LCD_HDOT == ? && LCD_VDOT == ?)

//----------------------------------类型声明---------------------------------//
// user_file 描述信息
typedef struct
{
	const char *name;
	/* 不使用文件系统时, 须增加如下成员以管理素材存储
		uint32_t addr; //起始地址
		uint32_t size; //大小偏移
	*/
} user_file_t;

// 文件类
typedef struct
{
	user_file_t *file;
	uint32_t table_size;
} table_class_t;

//----------------------------------全局变量声明---------------------------------//
//索引表
extern table_class_t File_Table;

#endif //__FILE_TABLE_H__
